import { RecoilState, selector } from 'recoil';
import { collapsedState } from '../atoms/collapsed';

export const collapsedSelector: RecoilState<boolean> = selector({
  key: 'collapsedSelector',
  get: ({ get }) => {
    return get(collapsedState);
  },
  set: ({ set }, newVal) => {
    set(collapsedState, newVal);
  }
});